package com.xayy.mgt.model;

import cn.kawins.mybatis.base.BaseModel;
import cn.kawins.mybatis.util.SnowflakeId;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
import io.swagger.annotations.ApiModelProperty;
import tk.mybatis.mapper.annotation.KeySql;

import javax.persistence.Column;
import javax.persistence.Id;
import javax.persistence.Table;
import java.util.Date;
import lombok.*;

/**
 * @author Nie
 * @version V1.0
 * @date 2023/9/19 9:32
 */
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@Table(name = "health_xw.bayes_health_record")
@EqualsAndHashCode(callSuper = true)
public class BayesHealthRecord extends BaseModel<Long> {

    @Id
    @ApiModelProperty(value = "主键")
    @KeySql(genId = SnowflakeId.class)
    @JsonSerialize(using = ToStringSerializer.class)
    @Column(name = "id")
    private Long id;
    /**
     * 卫星id
     */
    @ApiModelProperty(value = "卫星id")
    @Column(name = "satellite_id")
    private Long satelliteId;
    /**
     * 节点id
     */
    @ApiModelProperty(value = "节点id")
    @Column(name = "node_id")
    private Long nodeId;

    /**
     * 节点名称
     */
    @ApiModelProperty(value = "节点名称")
    @Column(name = "node_name")
    private String nodeName;

    /**
     * 评估时间
     */
    @ApiModelProperty(value = "评估时间")
    @Column(name = "health_time")
    private Date healthTime;

    /**
     * 健康度
     */
    @ApiModelProperty(value = "健康度")
    @Column(name = "health_score")
    private Double healthScore;

    /**
     * 健康等级
     */
    @Column(name = "health_level")
    @ApiModelProperty(value = "健康等级")
    private String healthLevel;
    /**
     * 权重
     */
    @Column(name = "weight")

    @ApiModelProperty(value = "权重")
    private Double weight;
}
